<template>
  <!-- 爱心 -->
  <div class="love-box" @click="love">
    <div class="love"></div>
    <div class="yuan1"></div>
    <div class="yuan2"></div>
  </div>
</template>
  
<script setup>
const emit = defineEmits(['love'])
const love = () => {
  emit('love')
}
</script>
  
<style lang="scss" scoped>
// 爱心
.love-box {
  position: absolute;
  right: 0;
  top: 0;
  width: 40px;
  height: 40px;

  .love {
    position: absolute;
    right: 0;
    top: 0;
    margin-right: 15px;
    margin-top: 16px;
    width: 12px;
    height: 12px;
    background-color: #f8355f;
    border-bottom: 1px solid #fff;
    border-left: 1px solid #fff;
    transform: rotate(-45deg);
    z-index: 15;
    transition: transform 0.5s;
  }

  .yuan1 {
    position: absolute;
    top: 0;
    left: 0;
    margin-top: 10px;
    margin-left: 7px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #f8355f;
    border: 1px solid #fff;
    z-index: 3;
  }

  .yuan2 {
    position: absolute;
    top: 0;
    left: 0px;
    margin-top: 10px;
    margin-left: 17px;
    width: 12px;
    height: 12px;
    background-color: #f8355f;
    border: 1px solid #fff;
    border-radius: 50%;
    z-index: 3;
  }
}
</style>
